
#ifndef _ka_system_thread_h
#define _ka_system_thread_h

#include "ka-system/types.h"

namespace ka {
    class Mutex {
    public:
        const static uint64_t WAIT_FOREVER = UINT64_MAX;
        Mutex();
        ~Mutex();
        bool lock(uint64_t timeoutMillis);
        void unlock();
    private:
        void *_data;
    };
    
    class ThreadLocal {
    public:
        ThreadLocal();
        ~ThreadLocal();
        void *getPointer();
        void setPointer(const void *ptr);
    private:
        void *_data;
    };
}

#endif
